package com.jake.microservice.stream.listener;

import com.jake.microservice.stream.bind.HelloBinding;
import lombok.extern.slf4j.Slf4j;
import org.springframework.cloud.stream.annotation.EnableBinding;
import org.springframework.cloud.stream.annotation.StreamListener;

@EnableBinding(HelloBinding.class)
@Slf4j
public class HelloListener {

    @StreamListener(target = HelloBinding.GREETING)
    public void processHelloChannelGreeting(String msg) {
        log.info("Listen RabbitMQ: {}", msg);
    }
}
